import QtQuick
import QtQuick.Controls

Page {
    title: "资源图片加载"
    
    Rectangle {
        anchors.fill: parent
        color: "#f0f0f0"
        
        Image {
            anchors.centerIn: parent
            source: "/images/logo.png"
            //sourceSize.width: 200      // 控制加载尺寸
            fillMode: Image.PreserveAspectFit
            
            // 添加加载状态提示
            Text {
                anchors.centerIn: parent
                visible: parent.status !== Image.Ready
                text: parent.status === Image.Loading ? "加载中..." : 
                      parent.status === Image.Error ? "加载失败" : ""
                color: "red"
            }
        }
    }
} 
